package com.cgwx.commonutils.math;

/**
 * @author GaoWei
 * @Date 2021/8/6 - 11:02
 */
public class DivNode extends OpNode
{
    public DivNode(Expression leftChild, Expression rightChild)
    {
        super(leftChild, rightChild);
    }

    public double eval(VarMap v, FuncMap f)
    {
        double a = this.leftChild.eval(v, f);
        double b = this.rightChild.eval(v, f);
        return a / b;
    }

    public String getSymbol()
    {
        return "/";
    }
}
